/*
 * 此配置类已被废弃，因为它与ApplicationConfig.java中定义的restTemplate Bean冲突
 * 请使用ApplicationConfig.java中的restTemplate Bean
 */
package com.example.shuiyin.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.http.client.SimpleClientHttpRequestFactory;
import org.springframework.web.client.RestTemplate;

// 此配置类已被禁用，避免Bean冲突
// @Configuration
public class RestTemplateConfig {

    // 此Bean定义与ApplicationConfig中的冲突
    // @Bean
    public RestTemplate restTemplate() {
        SimpleClientHttpRequestFactory factory = new SimpleClientHttpRequestFactory();
        factory.setConnectTimeout(5000);
        factory.setReadTimeout(15000);
        
        return new RestTemplate(factory);
    }
} 